home *** CD-ROM | disk | FTP | other *** search
- Path: bruce.cs.monash.edu.au!not-for-mail
- From: bmeyer@bruce.cs.monash.edu.au (Bernd Meyer)
- Newsgroups: comp.sys.amiga.programmer,comp.sys.amiga.advocacy,comp.os.ms-windows.advocacy
- Subject: Re: intuition inefficient ?
- Followup-To: comp.sys.amiga.programmer,comp.sys.amiga.advocacy,comp.os.ms-windows.advocacy
- Date: 2 Mar 1996 13:24:25 GMT
- Organization: Computer Science, Monash University, Australia
- Distribution: world
- Message-ID: <4h9i69$fi6@harbinger.cc.monash.edu.au>
- References: <4gm2qg$8lk@sunsystem5.informatik.tu-muenchen.de> <4grs7r$plr@harbinger.cc.monash.edu.au> <4gtq1c$mu0@sunsystem5.informatik.tu-muenchen.de>
- NNTP-Posting-Host: molly.cs.monash.edu.au
- X-NNTP-Posting-User: bmeyer
- X-Newsreader: TIN [UNIX 1.3 950823BETA PL0]
-
- Juergen "Rally" Fischer (fischerj@Informatik.TU-Muenchen.DE) wrote:
- : Bernd Meyer (bmeyer@bruce.cs.monash.edu.au) wrote:
- : : Juergen "Rally" Fischer (fischerj@Informatik.TU-Muenchen.DE) wrote:
- :
- : : what --- there is two standard ways to catch the vblank signal on a
- : : VGA card, and one of them is using an interrupt.
- :
- : Are you sure vblank interrupt is something "standard" on PC ?
- : I believe each newer VGA got the possibility to send such an
- : interrupt signal, but what about the _compatible_ way of using it ?
-
- What is the compatible way of using an interrupt? Sorry, I can't really
- answer this question for you, Juergen. If you don't know how to use
- an interrupt, you probably shouldn't discuss things like this. And
- BTW, it's not "newer" VGA cards --- it's been every VGA compatible card
- since the very first VGA card IBM delivered.
-
- : : register. This is due to the fact that almost everyone quickly disables
- : : the vblank interrupt as wasting valuable resources.
- :
- : _polling_ is waste of respources!
-
- No, using an IRQ line for something as trivial as the vblank signal is
- a waste of resources.
-
- : so double buffering is waste of
- : recources. efficient rastersplit free animation needs tripple buffering,
-
- No problem with that --- although you only need triple buffering if
- you can't guarantee that you get one screenful of data created in the
- time it takes to display one screen. If you could guarantee that, you'd
- have no need for triple buffering.
-
- : which needs either an interrupt or a gfx-hardware that will use a
- : write to adress-registers not immedeately, but after next vblank.
-
- *Grin* Well, Juergen, this sophisticated hardware you just described
- is _also_ in every single VGA card since the very first IBM has
- ever produced. At the start of every frame (at the vblank signal, so to
- say), the value of the "start of image memory" register is sampled into
- an internal latch. So you don't even have to get the timing of the
- register write right.....
-
- : : want an interrupt, you get one. How?
- : :[...]
- : : vblank signals. You can then set up one of those high precision timers
- :
- : one of those ? :) The _one and only_ which is able to cause interrupts
- : in a normal PC.
-
- There is two of them, actually.
-
- : : Now was that really so hard? All of the functionality used in this
- :
- : No :) I knew, my friend told me. He also told that there are some
- : problems. Such as interrupts occuring for the time the vblank bit
- : is set. bzzzt, another frame cpu busy-wait. Won't occur on a DOS demo,
- : but on a tasking environment it will.
-
- a) you could disable other interrupts for the time you wait. Very easy,
- and if you programmed your timer well, they are only disabled for
- a very short time
-
- b) You could set a certain timeout, after which you assume you missed
- the vblank and pretend it has been there, anyway. Be a bit more
- wasteful when reprogramming the timer, because you don't know how far
- down the image you are
-
- c) But most importantly: I don't think the VGA vblank bit gets reset
- by anything other than reading the register. Which would mean
- there is no way of "missing" it. I'm not sure, though, and I don't
- have a tech spec of the VGA standard handy at the moment.
- :
- : : You probably know where my money is. Have a look at the SVGALIB for
- : Yes, Bill Gates got it ;)
-
- If you still think that, Juergen, you are a lost case. I never paid
- a single cent, Pfennig, Oere, pecne or centime (and no other denomiations,m
- either) for an MS product. Never. Not once.
-
- : : : I can't believe they'll ever implement those nice little things A500
- : : : already had (vblank & stuff) into PC hardware _and_ the OSes (win, linux).
- :
- : : And I can't believe how narrow-minded you are, sorry.
- :
- : You didn't read exactly, I didn't tell about vblank-polling.
-
- And I explained two standard methods of getting vblank interrupts.
- Now I really can't do any more than offering TWO methods, right?
-
- : But as narrow-minded resource-wasting PCer you probably can't
- : think of anything more :)
-
- I can. Can you?
-
- Bernie
-
-